Skip to content

ci: stale-run sweeper — cancel superseded queued runs older than 6h (#2605) - #9993

Merged
dezren39 merged 1 commit into
mainfrom
queue/16678-2605-stale-sweeper
Nov 14, 2026
Merged

dezren39 merged 1 commit into
mainfrom
queue/16678-2605-stale-sweeper

Conversation

@dezren39

@dezren39 dezren39 commented Nov 14, 2026 •

Copy link
Copy Markdown
Member

Implements the sweeper half of the #2605 follow-on packet (task 16678).

New: stale-run sweeper workflow

.github/workflows/stale-run-sweeper.yml — runs every 2h (and on workflow_dispatch, with dry_run and threshold_hours inputs). It cancels queued runs that are both older than the threshold (default 6h) and superseded — their head SHA is no longer their branch's head (a deleted branch counts as superseded). It never touches in-progress runs, young runs, or runs whose SHA is still the branch head. Every decision (cancel/keep + reason) is written to the job summary as the auditable log.

Dry-run validation of the exact selection logic against the live queue (2026-11-14, this shift): 244 queued total; 89 queued >6h; all 89 superseded; 0 still-head — the stale population the #2605 triage measured (88 runs from 2026-11-11) is still sitting there.

Concurrency half — already in place (finding, no change)

The packet asked for concurrency: cancel-in-progress on the two largest fan-out workflows (mcpx test, id). Both already have it: mcpx-test.yml and id-check.yml carry cancel-in-progress: true with per-ref groups for non-push events. Their push-to-main runs are deliberately keyed by run_id (documented in id-check.yml: a later merge must never cancel an earlier merge's verification) — which is precisely the queued population a concurrency group cannot reap, and the one this sweeper now handles. No concurrency change is made; changing the push keying would contradict that documented design.

Task 16678, lane code-d.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@dezren39
dezren39 requested a review from a team as a code owner November 14, 2026 12:59
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-14T12:59:59.643664Z
We couldn’t complete this review. Comment @codex review to try again.
62e6a5c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Nov 14, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 29 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 970f4917-5cd1-4025-a664-84fcfa43e7e5
Commits

Reviewing files that changed from the base of the PR and between b71b7a5 and 62e6a5c.

Files selected for processing: 1

  • .github/workflows/stale-run-sweeper.yml
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant